// import { RouteRecordRaw } from "vue-router";
import Layout from "_l/index.vue";

export default {
  path: "/user",
  component: Layout,
  name: "user",
  redirect: "/user/list", // "/" 重定向只能跳转 type="page" 的目标
  // name: "room",
  meta: {
    id: "user",
    title: "menu.user.module",
    icon: "fa-solid fa-user",
    type: "module"
  },
  children: [
    {
      path: "list",
      name: "user_list",
      component: () => import("_p/user/list/index.vue"),
      meta: {
        id: "user_list",
        title: "menu.user.list",
        icon: "fa-solid fa-user-group",
        limits: ["add", "edit", "delete"],
        type: "page"
      }
    },
    {
      path: "role",
      name: "user_role",
      component: () => import("_p/user/role/index.vue"),
      meta: {
        id: "user_role",
        title: "menu.user.role",
        icon: "fa-solid fa-user-tag",
        limits: ["add", "edit", "delete"],
        type: "page"
      }
    },
    {
      path: "menu",
      name: "user_menu",
      component: () => import("_p/user/menu/index.vue"),
      meta: {
        id: "user_menu",
        title: "menu.user.menu",
        icon: "fa-solid fa-align-left",
        limits: ["add", "edit", "delete"],
        type: "page"
      }
    }
  ]
};
